#ifndef MAKI_H_
#define MAKI_H_

#include <vector>
#include <string>

#include <cv.h>

class FeatureDetector;
class GUI;
class VarianceCorrelator;
class DataWriter;

class MaKI
{
public:
	MaKI();
	virtual ~MaKI();
	
public:
	
	bool   loadImage(std::string filename, IplImage* &image);
	CvMat* findHomography(CvSeq* seqMatches);
	void   findFundamentalMatrix(CvSeq* featurePairs);
	void   processImages(std::string filePath, std::vector<std::string> fileNames);
	void   getFileNames(std::string basePath, std::string pattern, std::vector<std::string>& fileNames, bool returnFullPaths);
	
	
private:
	void testHomography(IplImage* image1, IplImage* image2, CvSeq* currentPairs, CvMat* homography, int leftIndex, int rightIndex);
	void adjustPairIDs(CvSeq* featurePairs, int leftImageID, int rightImageID);
	
	
	FeatureDetector* featureDetector;
	GUI* gui;
	VarianceCorrelator* correlator;
	DataWriter* dataWriter;

};

#endif /*MAKI_H_*/
